#define _CRT_SECURE_NO_WARNINGS
int* masterMind(char* solution, char* guess, int* returnSize)
{
    *returnSize = 2;
    int* ret = malloc(sizeof(int) * (*returnSize));
    int i = 0;
    ret[0] = 0;
    ret[1] = 0;
    for (i = 0; i < 4; i++)
    {
        if (solution[i] == guess[i])
        {
            ret[0]++;
            solution[i] = "A";
            guess[i] = "C";
        }
    }
    int j = 0;
    for (i = 0; i < 4; i++)
    {
        for (j = 0; j < 4; j++)
        {
            if (solution[j] == guess[i])
            {
                ret[1]++;
                solution[j] = "A";
                guess[i] = "C";
            }
        }
    }
    return ret;
}